package com.atguigu.lease.web.app.custom.interceptor;

import org.springframework.context.annotation.Configuration;
import org.springframework.web.servlet.config.annotation.InterceptorRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;

/**
 * @author Tsuchi
 * @description TODO
 * @date 2024/12/25 19:45
 */
@Configuration
public class MyWebMvcConfig implements WebMvcConfigurer {
	@Override
	public void addInterceptors(InterceptorRegistry registry) {
		registry.addInterceptor(new LoginInterceptor())
			.addPathPatterns("/app/**").excludePathPatterns("/app/login/**");
	}
}
